'''
Created on 2010-7-4

@author: me
'''
import os
import time

#The files and directories to be backed up are specified i a list.
#source = ['/home/swaroop/byte', '/home/swaroop/bin']
source = [r'C:\documents',r'D:\work']
target_dir = '/mnt/e/backup/' # Remember to change this to what you will be using

target = target_dir + time.strftime('%Y%m%d%H%M%S') + '.zip'

zip_command = "zip -qr '%s' %s" % (target, ' '.join(source))
if os.system(zip_command) == 0:
    print 'Successful backup to', target
else:
    print 'Backup FAILED, zip command not find.' 


